package com.edgar.download;

import android.content.Context;

/**
 * Created by xiexiang on 2015/11/3.
 * 状态信息帮助类
 */
public class StatusHelp {

    private Context mContext;

    public StatusHelp(Context context){
        this.mContext = context;
    }

    public String getDownloadStatusInfo(Download download){
        String statusInfo = "下载";
        if(download == null){
            return statusInfo;
        }
        switch (download.getStatus()){
            case Constant.SUCCESS:
                statusInfo = "下载完成";
                break;
            case Constant.DOWNLOADING:
                statusInfo = "暂停";
                break;
            case Constant.START:
                statusInfo = "准备下载";
                break;
            case Constant.WAIT:
                statusInfo = "等待下载";
                break;
            case Constant.PAUSE:
                statusInfo = "继续";
                break;
        }
        return statusInfo;
    }
}
